Data processors commonly implement one or more levels of cache memory for temporary storage of information. Caches are used to bring data closer to the processing element and reduce data access time. Many techniques exist to efficiently manage cache memory systems. In high performance reliable systems, two techniques necessary for efficiently managing cache memory systems are the ability to preload custom data into the cache and the ability to detect and correct bit errors.
Users of data processing systems frequently desire to reduce latency to memory by preloading a cache with proprietary application-specific data. The common techniques involve the processor executing the steps required to bring data into its cache by using either software or hardware. The software technique for preloading caches involves inserting specific instructions in the program flow being executed in the data processing system. The hardware technique involves adding hardware to analyze the access pattern and dynamically prefetch code and data that is considered likely to be accessed. These techniques are generally limited to the processor executing steps required to bring data into its cache and do not permit an external agent to preload data into a processor cache.
Cache memory systems implement error detection to discover and potentially correct bit errors in the stored information. Two commonly used error detection techniques are the parity bit error detection method and the more complex error correcting (ECC) method. Due to speed requirements, modern data processors generally only implement a simple error detection technique in their level one cache. ECC is more commonly implemented in level two memories than in level one memories.
The parity bit method is simpler to implement, but has less functionality than the ECC method. For example, the parity bit method is capable of only detecting single bit errors while the ECC method is capable of both detecting and correcting single bit errors. Additionally, the ECC method may detect multiple bit errors.
Recovering from a parity bit error in a level one cache involves invalidating the level one cache. Some caches support invalidation of single storage lines while others require a complete erasure or flushing of all entries in the cache. Either invalidation method requires that the level one cache treat all stores (i.e. writes) as a write-through process in which both the cache and a system memory are updated. A downside of this technique is increased traffic to the lower levels of the memory hierarchy that results in overall slower system performance.
For the ECC methods, system performance is degraded due to several reasons. Initially, an ECC code must be generated and this code generation takes time and additional system resources. Storage must be provided for the ECC code in the level one cache. When data is read, the ECC is calculated again and compared with the stored ECC code. When the number of bits that are written to the level one cache is smaller than the size of the data that is used to generate the ECC code, a read/modify/write process involving the level one cache is required to calculate the ECC code. Therefore, while this process is occurring, the level one cache is not available for other processing functions. A need exists for a more efficient data processing system that implements error handling.
Skilled artisans appreciate that elements in the figures are illustrated for simplicity and clarity and have not necessarily been drawn to scale. For example, the dimensions of some of the elements in the figures may be exaggerated relative to other elements to help improve the understanding of the embodiments of the present invention.